home *** CD-ROM | disk | FTP | other *** search
- Ultimate Calculator v3.2 (Unregistered) [F1] for help
- Copyright (C) 1992-1996 by Daniel Corbier. All rights reserved.
-
- ucalc> ;*******************************************************************
- ucalc> ; This text file is a sample session which demonstrates some of the
- ucalc> ; features available in the Ultimate Calculator. The sections are
- ucalc> ; entitled:
- ucalc> ;
- ucalc> ; 1. General Calculations
- ucalc> ; 2. Physics for Thought
- ucalc> ; 3. HBO for Thought
- ucalc> ; 4. Are you converted yet?
- ucalc> ; 5. Let's use some FORCE
- ucalc> ; 6. How to pay
- ucalc> ; 7. Let's get a few FACTS straight
- ucalc> ;*******************************************************************
- ucalc>
- ucalc> ; ***********************
- ucalc> ; 1. General Calculations
- ucalc> ; ***********************
- ucalc>
- ucalc> 17*(5+8)^2
- Answer: 2873
-
- ucalc> cos(pi)+8/pi + sinh(14)
- Answer: 601303.688561062095
-
- ucalc> test(x) = x^pi + sin(x) ; User defined function.
- ucalc> test(14)
- Answer: 3988.18506502600842
-
- ucalc> sum(x*2+3^x,1..100) ; Summation
- Answer: 7.73066281098016997E+47
-
- ucalc>
- ucalc> ; **********************
- ucalc> ; 2. Physics for Thought
- ucalc> ; **********************
- ucalc>
- ucalc> mass = 77.2 ; g
- MASS= 77.2
-
- ucalc> Volume = 4.0 ; cm^3
- VOLUME= 4
-
- ucalc>
- ucalc> mass / Volume ; Density
- Answer: 19.3
-
- ucalc>
- ucalc> mass = 13 ; Lets try a different mass
- MASS= 13
-
- ucalc>
- ucalc> mass / Volume ; Now lets see the new density
- Answer: 3.25
-
- ucalc> ; Quantum Mechanics
- ucalc>
- ucalc> h = 6.63E-34 ; J s
- H= 6.63E-34
-
- ucalc> m = 9.11E-31 ; kg
- M= 9.11E-31
-
- ucalc> L = 2E-11 ; m
- L= .00000000002
-
- ucalc>
- ucalc> E(x) = (h^2/(8*m*L^2))*x^2 ; Allowed energies for a particle in a box.
- ucalc>
- ucalc> E(1)
- Answer: 1.50785194840834248E-16
-
- ucalc> ; Oops, you meant L=2E-10, no problem use the Up arrow.
- ucalc> L = 2E-10
- L= .0000000002
-
- ucalc> E(1) ; You didn't have to retype the eq. ! Time saver, isn't it?
- Answer: 1.50785194840834248E-18
-
- ucalc> E(5)
- Answer: 3.7696298710208562E-17
-
- ucalc>
- ucalc> ; ******************
- ucalc> ; 3. HBO for Thought
- ucalc> ; ******************
- ucalc>
- ucalc> mode hbo ; Results will be displayed in Hex, Binary, and Octal
-
- ucalc>
- ucalc> #h1E or #hAFF ; ORing two hexadecimal numbers
- Decimal: 2815 Hex: AFF Binary: 101011111111 Octal: 5377
-
- ucalc>
- ucalc> $1E or $AFF ; Same as above (shortcut notation for hex)
- Decimal: 2815 Hex: AFF Binary: 101011111111 Octal: 5377
-
- ucalc>
- ucalc> #b1010101 or #b111000 + 44/2
- Decimal: 95 Hex: 5F Binary: 1011111 Octal: 137
-
- ucalc>
- ucalc> mode hbo ; Toggle HBO mode back off
-
- ucalc>
- ucalc> ; *************************
- ucalc> ; 4. Are you converted yet?
- ucalc> ; *************************
- ucalc>
- ucalc> feet_inches(x) = x * 12 ; You can put these and more in
- ucalc> meters_feet(x) = 3.281 * x ; UCALC.DEF if you use them often.
- ucalc> celsius_fa(x) = 9/5 * x + 32 ; Celsius to Fahrenheit.
- ucalc>
- ucalc> celsius_fa(50)
- Answer: 122
-
- ucalc> feet_inches(3)
- Answer: 36
-
- ucalc>
- ucalc> ; ***********************
- ucalc> ; 5. Let's use some FORCE
- ucalc> ; ***********************
- ucalc>
- ucalc> ; FORCE = integral( pgh dA )
- ucalc>
- ucalc> integ 3x^2*(x+7),4..7
- Answer: 3561.75
-
- ucalc> integ 6.24*(3-x)*2*sqr(9-x^2),-3..3,1000 ; 1000 for higher precision
- Answer: 529.288609103337383
-
- ucalc>
- ucalc> ; *************
- ucalc> ; 6. How to pay
- ucalc> ; *************
- ucalc>
- ucalc> ; You can do all your financial calculations with UCALC.
- ucalc>
- ucalc> ; Lets take a loan to buy a nice house
- ucalc>
- ucalc> payment(PV,i,n) = PV*i/(1-(1+i)^(-n)) ; Formula for monthly payments
- ucalc>
- ucalc> PV = 175000 ; Loan balance
- PV= 175000
-
- ucalc> i = .01 ; Interest rate (1% monthly)
- I= .01
-
- ucalc> n = 240 ; Number of payments (20 years)
- N= 240
-
- ucalc>
- ucalc> payment(PV,i,n)
- Answer: 1926.90073374681746
-
- ucalc> n = 360 ; Maybe we can negotiate better terms
- N= 360
-
- ucalc>
- ucalc> payment(PV,i,n)
- Answer: 1800.07204461963275
-
- ucalc> payment(215000,i,n) ; Can we afford a bigger loan?
- Answer: 2211.51708338983452
-
- ucalc>
- ucalc> ; You want to become a millionaire by investing $50,000 and
- ucalc> ; earning 14% interest each year. How many years will it take?
- ucalc>
- ucalc> Term(FV,PV,i) = ln(FV/PV) / ln(1+i)
- ucalc>
- ucalc> FV = 1000000 ; Future investment value
- FV= 1000000
-
- ucalc> PV = 50000 ; Present investment value
- PV= 50000
-
- ucalc> i = .14 ; Annual interest
- I= .14
-
- ucalc>
- ucalc> Term(FV,PV,i)
- Answer: 22.8632526947680305
-
- ucalc> ; It will take around 23 years
- ucalc>
- ucalc> ; *********************************
- ucalc> ; 7. Let's get a few FACTS straight
- ucalc> ; *********************************
- ucalc>
- ucalc> FACT(1500)*2
- Answer: 9.62399559355954972E+4114
-
- ucalc> 1500!*2 ; version 2.+ now supports the factorial (!) symbol.
- Answer: 9.62399559355954972E+4114
-
- ucalc> ; Wow, not even the US budget deficit is that big of a number.
- ucalc> ; Can your pocket calculator get a factorial that high?
- ucalc>
- ucalc> solve( exp(x)+3*x = 15 )
- Answer: 2.14698767937181217
-
- ucalc> ; 'last' stores the answer to the previous operation.
- ucalc> exp(last)+3*last ; You can use that concept for accuracy checks.
- Answer: 15
-
- ucalc> solve( sin(x) = 1, 0..pi )
- Answer: 1.57079632679489662
-
- ucalc> sumtable(x^2+2*x,0..10)
- Count Value Cumulative
- 0 0 0
- 1 3 3
- 2 8 11
- 3 15 26
- 4 24 50
- 5 35 85
- 6 48 133
- 7 63 196
- 8 80 276
- 9 99 375
- 10 120 495
- Answer: 495
-
- ucalc>
- ucalc> ; Compound functions can be defined by using relational operators.
- ucalc>
- ucalc> ; / x^2+3, x > 0
- ucalc> ; tst(x) = | 2, x = 0
- ucalc> ; \ x^2-3, x < 0
- ucalc>
- ucalc> tst(x) = (x^2+3)*(x>0) + (2)*(x=0) + (x^2-3)*(x<0)
- ucalc> tst(15)
- Answer: 228
-
- ucalc> tst(-8)
- Answer: 61
-
- ucalc> 3*tst(0)^2+pi
- Answer: 15.1415926535897932
-
- ucalc>
- ucalc> ; These are just some of the things you can do with UCALC.
- ucalc>
- ucalc> ; Please remember to pay the registration fee. This will allow me
- ucalc> ; to spend the necessary amount of time in order to add some of the
- ucalc> ; features that you would like to see in the next version.
- ucalc>